Skip to content

Conversation

@hinerm
Copy link
Member

@hinerm hinerm commented Apr 30, 2015

This change leans on the new ModuleService#getDefaultValue(ModuleItem) method, which is smarter about default value computation across the board. It avoids the pitfall of bounding min/max using the widget model's min and max—which fall back to the numeric type's min/max values for the purposes of bounding the widget—and instead uses the ModuleItem's stated default/min/max, or a default converted from "0" if none.

@ctrueden ctrueden changed the title DO NOT MERGE Improve handling of default values Apr 30, 2015
This change leans on the new ModuleService#getDefaultValue(ModuleItem)
method, which is smarter about default value computation across the
board. It avoids the pitfall of bounding min/max using the widget
model's min and max -- which fall back to the numeric type's min/max
values for the purposes of bounding the widget -- and instead uses the
ModuleItem's stated min/max, or a default converted from "0" if none.
@hinerm hinerm force-pushed the default-values branch from b1bfe66 to 7dc0af5 Compare May 1, 2015 16:54
@hinerm hinerm merged commit 7dc0af5 into master May 1, 2015
@ctrueden ctrueden deleted the default-values branch May 1, 2015 16:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants